import { ColumnsType } from "@/components";

/**
 * Table 字段对应 Label
 */
export enum TableLabel {
    Id = "ID",
    ShopCode = "店铺编码",
    ShopName = "门店名称",
    DishGuid = "菜式唯一编码",
    DishCode = "菜式编码",
    DishName = "菜式名称",
    Price = "价格",
    Extra = "额外参数",
    CreatedAt = "创建时间",
}

export const columns: ColumnsType[] = [
    {
        minWidth: 100,
        label: TableLabel.Id,
        prop: "Id"
    },
    {
        minWidth: 120,
        label: TableLabel.ShopCode,
        prop: "ShopCode"
    },
    {
        minWidth: 120,
        label: TableLabel.ShopName,
        prop: "ShopName"
    },
    {
        minWidth: 120,
        label: TableLabel.DishGuid,
        prop: "DishGuid"
    },
    {
        minWidth: 120,
        label: TableLabel.DishCode,
        prop: "DishCode"
    },
    {
        minWidth: 120,
        label: TableLabel.DishName,
        prop: "DishName"
    },
    {
        minWidth: 120,
        label: TableLabel.Price,
        prop: "Price"
    },
    {
        minWidth: 200,
        label: TableLabel.Extra,
        prop: "Extra"
    },
    {
        width: 180,
        DateFormat: true,
        sortable: true,
        label: TableLabel.CreatedAt,
        prop: "CreatedAt"
    },
]